package org.apache.jmeter.gui.rcp.tree;

import org.eclipse.jface.viewers.IStructuredContentProvider;
import org.eclipse.jface.viewers.ITreeContentProvider;
import org.eclipse.jface.viewers.Viewer;

public class JMeterTreeViewContentProvider implements IStructuredContentProvider,
		ITreeContentProvider 
{

    public void inputChanged(Viewer v, Object oldInput, Object newInput) {
	}
    
	public void dispose() {
	}
    
	public Object[] getElements(Object parent) {
		return getChildren(parent);
	}
    
	public Object getParent(Object node) {
		return ((JMeterTreeNode)node).getParent();
	}
    
	public Object[] getChildren(Object node) {
		return ((JMeterTreeNode)node).getChildren();
	}

    public boolean hasChildren(Object node) {
		return ((JMeterTreeNode)node).hasChildren();
	}
}
